function getMediaSource(){
	var str_mcId='';
	str_mcId = str_mcId= getRequest("WT.mc_id");
	if(!str_mcId||str_mcId=="null"||str_mcId=="undefined"){str_mcId=getCookie("MEDIA_SOURCE_NAME");}
	if(!str_mcId||str_mcId=="null"||str_mcId=="undefined"){str_mcId=document.getElementById("WT.mc_id")?document.getElementById("WT.mc_id").value:"";}
	if(!str_mcId||str_mcId=="null"||str_mcId=="undefined"){str_mcId=getReferrer();}
	if(!str_mcId||str_mcId=="null"||str_mcId=="undefined"){str_mcId="direct";}
	return str_mcId;
}
function getRequest(param_name){
	return (window.location.search.match(new RegExp('[&?]'+param_name + '=([^&]*)', 'i')) || [''])[0].split('=')[1];
}
function getCookie(cookie_name) {
	var allcookies = document.cookie;
	var cookie_pos = allcookies.indexOf(cookie_name);
	if(cookie_pos != -1){
		cookie_pos += cookie_name.length + 1;
		var cookie_end = allcookies.indexOf(";", cookie_pos);
		if (cookie_end == -1) {
		       cookie_end = allcookies.length;
		}
		var value = unescape(allcookies.substring(cookie_pos, cookie_end));
		return value;
	}else{
		return '';
	}
}
function getReferrer(){
	var thisReferrer = document.referrer; //获取访前
	if(thisReferrer!=''){
		thisReferrer = thisReferrer.match(/(^(https|http):\/\/).*\//i)[0].substring(0,40);
	}
	return thisReferrer;
}